package com.ifengchao.job;

import com.ifengchao.service.DealPlanService;
import org.apache.log4j.Logger;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

/**
 * @Author YiMing
 * @Description:
 * @Date: Created in 下午7:27 2017/8/31
 * @Modified By
 */
@Component("dealPlanJob")
public class DealPlanJob {

	private static final Logger logger = Logger.getLogger(DealPlanJob.class);

	@Autowired(required = true)
	private DealPlanService dealPlanService;

	/**
	 * 计划投放统计逻辑
	 */
	public void executeTask() {
		System.out.println("-----进入计划投放统计逻辑job------");
		logger.info("-----进入计划投放统计逻辑job------");
		try {
			dealPlanService.getPlanStatistics();
		} catch (Exception e) {
			logger.error("计划投放统计逻辑出错：", e);
		}
	}
}
